package models

import (
	"time"
)

// YhCart undefined
type Cart struct {
	ID           int64     `json:"id" gorm:"id"`
	UserId       int64     `json:"user_id" gorm:"user_id"`
	ProductId    int64     `json:"product_id" gorm:"product_id"`
	Num          int64     `json:"num" gorm:"num"`
	SpecType     int8      `json:"spec_type" gorm:"spec_type"`
	ProductSkuId int64     `json:"product_sku_id" gorm:"product_sku_id"`
	SpecInfo     string    `json:"spec_info" gorm:"spec_info"`
	ProductName  string    `json:"product_name" gorm:"product_name"`
	CreatedAt    time.Time `json:"created_at" gorm:"created_at"`
	UpdatedAt    time.Time `json:"updated_at" gorm:"updated_at"`
}

// TableName 表名称
func (*Cart) TableName() string {
	return "dg_cart"
}